﻿@model MobileSales.Model.Clients.Client

@{
    View.Title = Strings.Clients + " - " + Strings.Create;
    Layout = "~/Views/Shared/_Layout.cshtml";
}

<h2>@Strings.Clients &nbsp;&raquo;&nbsp; @Strings.Create</h2>

@using (Html.BeginForm()) {
    @Html.ValidationSummary(true)
    <fieldset>
        <legend>@Strings.Fields</legend>

        <div class="editor-label">
            @Html.LabelFor(model => model.Name)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.Name)
            @Html.ValidationMessageFor(model => model.Name)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.Name2)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.Name2)
            @Html.ValidationMessageFor(model => model.Name2)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.Nip)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.Nip)
            @Html.ValidationMessageFor(model => model.Nip)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.Zipcode)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.Zipcode)
            @Html.ValidationMessageFor(model => model.Zipcode)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.City)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.City)
            @Html.ValidationMessageFor(model => model.City)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.Street)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.Street)
            @Html.ValidationMessageFor(model => model.Street)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.Phone)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.Phone)
            @Html.ValidationMessageFor(model => model.Phone)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.Fax)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.Fax)
            @Html.ValidationMessageFor(model => model.Fax)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.Info)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.Info)
            @Html.ValidationMessageFor(model => model.Info)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.Info2)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.Info2)
            @Html.ValidationMessageFor(model => model.Info2)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.Debts)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.Debts)
            @Html.ValidationMessageFor(model => model.Debts)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.IsSupplier)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.IsSupplier)
            @Html.ValidationMessageFor(model => model.IsSupplier)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.Group)
        </div>
        <div class="editor-field">
            @Html.ClientGroupSelect("clientGroupId")
        </div>
        
        @Html.ParamsEditorsFor(MobileSales.Model.Params.ParamType.Client)
        <p>
            <input type="submit" value="@Strings.Create" />
        </p>
    </fieldset>
}

<div>
        @Html.ActionLink(Strings.BackToList, "Index", null, new { @class="icon-button prev-icon" })
</div>

